import { BrowserRouter, Route, Routes } from "react-router-dom";
import routes from "@/router";
import { ConfigProvider } from "zarm";
import zhCN from "zarm/lib/config-provider/locale/zh_CN";


function App() {
  return (
      <BrowserRouter>
        <ConfigProvider locale={zhCN}>
          <Routes>
            {routes.map((route, index) => (
              <Route
                key={index}
                path={route.path}
                element={<route.component />}
              />
            ))}
          </Routes>
        </ConfigProvider>
      </BrowserRouter>
  );
}

export default App;
